﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace LevenBlog.Core.Entities
{
    [Serializable]
    [DataContract(Name = "tagmap")]
    [Table("lb_tagmap",Info="")]
    public class lb_tagmap :BaseEntity
    {
        [DataMember]
        [Column("id", DataType.Int32, Length = 4, CanNull = false, AutoIncrement = true, PrimaryKey = true)]
        public int id { get; set; }

        [DataMember]
        [Column("blogid", DataType.Int32, Length = 4, CanNull = false)]
        public int blogid { get; set; }

        [DataMember]
        [Column("tagid", DataType.Int32, Length = 4, CanNull = false)]
        public int tagid { get; set; }

        [DataMember]
        [LinkTable("lb_blog", SqlPrefix = "blog_")]
        public lb_blog blog { get; set; }

        [DataMember]
        [LinkTable("lb_tag", SqlPrefix = "tag_")]
        public lb_tag tag { get; set; }
    }
}
